package com.net.ip;

import java.io.Console;
import java.io.IOException;
import java.net.InetAddress;
import java.util.Scanner;

import com.net.ip.vo.TcpScanFinTabVo;

import jpcap.*;
import jpcap.packet.*;

public class test {

	/**
	 * @param args
	 * @throws IOException
	 * @throws InterruptedException 
	 */
	public static void main(String[] args) throws IOException, InterruptedException {
//		test2();
		test1();
		            
	}
	

	
	public static  void test1 () throws IOException, InterruptedException
	{
		TcpScan finscan = new TcpScan();
		finscan.tcpFinScan();
		finscan.output();
		
//		finscan.tcpFinScan();
		
	}
	
	public static void test2() throws IOException 
	{
		System.out.println("Choose the kind of protocol ,such as tcp/udp or ip:");
		Scanner scanner = new Scanner(System.in);
        String str = scanner.nextLine();
       
        PacketsCapter test = new PacketsCapter();
        
        if (str.equals("tcp"))
        	test.TcpPackets(2);
        else if (str.equals("udp"))
        	test.UdpPackets(2);
        else 
        	test.IpPackets(2);      
        
        System.exit(0);  
	}
}
